home *** CD-ROM | disk | FTP | other *** search
/ Multimedia Selection / Multimedia Selection Volume One - CD-ROM / MULTIMEDIA SELECTION____________.ISO / grafica / dos / theimage / theimage.doc < prev    next >
Encoding:
Text File  |  1993-07-30  |  13.1 KB  |  325 lines

  1.  
  2.  
  3.  
  4.  
  5.                                T h e I m a g e
  6.                                ---------------
  7.  
  8.                                 Version 1.00
  9.                           Released July 31th, 1993
  10.  
  11.          Copyright (C) 1993 by José De Almeida. All Rights Reserved.
  12.                  P.O.Box 4185. 1504 Lisboa Codex. Portugal.
  13.  
  14.  
  15.  
  16.                           --- COPYRIGHT NOTICE ---
  17.  
  18.  
  19.  
  20.   TheImage is Copyright (C) 1993 by José De Almeida.
  21.  
  22.   TheDraw is Copyright (C) 1986-1993 by TheSoft Programming and Ian E. Davis.
  23.  
  24.   Turbo Pascal is Copyright (C) 1983-1992 by Borland International, Inc.
  25.  
  26.   TheImage, its  accompanying documentation, have been  released as Shareware,
  27.   but it is not Freeware or Public Domain software.
  28.  
  29.   If you  find this program usefull  to you, and you  plan to use it  after 15
  30.   days of  evaluation period, you  must send  me  US $5 dolars,  which will be
  31.   pretty  much  appreciated.  All  contributions   will  help  me  keeping  on
  32.   developping shareware and freeware programs. See bellow for mail address.
  33.  
  34.   No part of  TheImage may be modified, altered,  reverse engineered, sold, or
  35.   distributed in any form which would involve some sort of trade without prior
  36.   written permission from the Author.
  37.  
  38.  
  39.  
  40.                               --- REGISTER ---
  41.  
  42.  
  43.  
  44.   After 15 days evaluation peridod, if  you find this program usefull, and you
  45.   plan to  use it in  future, a $5  contribution is required.  Send your money
  46.   payable to José De Almeida, to the following address:
  47.  
  48.       ■ José De Almeida
  49.         P.O.Box 4185
  50.         1504 Lisboa Codex
  51.         Portugal
  52.  
  53.   Please specify your name and address. Be sure, I'll apreciate it very much !
  54.   Thanks in advance.
  55.  
  56.  
  57.  
  58.                              --- DISCLAIMER ---
  59.  
  60.  
  61.  
  62.   This program is provided "as is" without warranty of any kind.
  63.  
  64.   In addition, the Author specifically  disclaims all warranties, expressed or
  65.   implied, including but not limited  to implied warranties of merchantability
  66.   and fitness for a particular purpose  and TheImage license granted herein in
  67.   particular,  and without  limiting operation  of TheImage  gram license with
  68.   respect to any particular application, use, or purpose.
  69.  
  70.   In no event shall the Author be liable for any loss of profit, lost savings,
  71.   commercial damage, or other incidental  or consequential damages arising out
  72.   of the use or inability to use TheImage even if the Author, José De Almeida,
  73.   or an authorized distributor of TheImage has been advised of the possibility
  74.   of such damages, or for any claim by any other party.
  75.  
  76.  
  77.  
  78.                                --- LICENSE ---
  79.  
  80.  
  81.  
  82.   As any Shareware program, you may freely distribute TheImage, subject to the
  83.   following restrictions:
  84.  
  85.       ■ TheImage  must  be distributed  in an  unmodified form,  including the
  86.         TheImage documentation file and description file FILE_ID.DIZ.
  87.  
  88.         Particularly,  SysOps  MUST  keep  inside  the  archive  the  original
  89.         FILE_ID.DIZ description file, as it is distributed by the Author. This
  90.         will give BBS users the correct  and same good description for all BBS
  91.         users over the world.
  92.  
  93.       ■ TheImage  may not be  included with any  other product for  any reason
  94.         whatsoever without prior written consent from José De Almeida.
  95.  
  96.       ■ No  charge or payment  may be accepted  for TheImage, without  written
  97.         permission from the Author.
  98.  
  99.   Bulletin  Board  System  Operators  may  post  TheImage  on  their  BBS  for
  100.   downloading  by their  users without  written permission,  only if the above
  101.   conditions  are met,  and only  if  no  special fee  is necessary  to access
  102.   TheImage files (a general fee to access the BBS is acceptable).
  103.  
  104.   Distributors  of Shareware  and Public  Domain software  MUST obtain written
  105.   permission from José De Almeida before distributing TheImage and must follow
  106.   the above conditions. Permission is  almost always granted; this requirement
  107.   is necessary to ensure protection for  the Author and users of TheImage from
  108.   unscrupulous individuals.
  109.  
  110.  
  111.  
  112.                           --- CUSTOMER SUPPORT ---
  113.  
  114.  
  115.  
  116.   Full support to users of TheImage is available through one major channel. If
  117.   you wish contact the Author  with questions, suggestions, problems, or other
  118.   comments:
  119.  
  120.       ■ Call the TheImage's worldwide support Bulletin Board System:
  121.  
  122.             THE IMAGE BANK BBS
  123.             -------------------
  124.             SysOp: Jose Almeida
  125.  
  126.             Node #1: +351-1-7786640 * 20-07h (7 days a week)
  127.                      Intel SatisFAXtion Modem /400e * 14.4k * V.32bis
  128.  
  129.             RIME site: ->TIB   (or #5314)
  130.  
  131.             Mail address: P.O.Box 4185.  1504 Lisboa Codex.  Portugal.
  132.  
  133.         Here I can be reached in the following conference:
  134.  
  135.             (LOCAL): SUPPORT
  136.             RIME   : SYSOPS
  137.                    : COMMON
  138.  
  139.  
  140.  
  141.                            --- FILES INCLUDED ---
  142.  
  143.  
  144.  
  145.   The TheImage is distributed in a archive  ZIP file. Please do not change the
  146.   archive  contents or  add any  file. The  archive name  is THEIMAGE.ZIP, and
  147.   contains the following files:
  148.  
  149.       ■ THEIMAGE.EXE - The program
  150.       ■ THEIMAGE.DOC - The documentation
  151.       ■ HISTORY.DOC  - Version history
  152.       ■ FILE_ID.DIZ  - Description  file  for  PCBoard  systems (please do not
  153.                        delete  or change  this  file;  this file  provides the
  154.                        Author's description of the archive)
  155.       ■ DEMO.EXE     - Demo program on how to  use TheImage and a TheDraw .ASM
  156.                        file
  157.       ■ DEMO.PAS     - Source code for the demo program
  158.       ■ DEMO_IMG.ASM - .ASM file of  the demo program screen image,  generated
  159.                        by The Draw
  160.       ■ DEMO_IMG.PAS - .PAS file of the demo  program screen image,  converted
  161.                        by TheImage
  162.       ■ DEMO_IMG.TD  - Original TheDraw file for the demo program screen image
  163.       ■ THEDRAW.PAS  - Almost  the  original   UNCRUNCH.PAS  file  bundled  in
  164.                        TheDraw; I have implemented it as a full TP unit
  165.       ■ SOFTWARE.DOC - The complete list,  along with brief description of all
  166.                        my Shareware and Freeware programs
  167.  
  168.  
  169.  
  170.                          --- PROGRAM DESCRIPTION ---
  171.  
  172.  
  173.  
  174.   There isn't really nothing much to say about TheImage.
  175.  
  176.   TheImage  generates Turbo  Pascal .PAS   complete source  code Unit,  from a
  177.   TheDraw screen  image previously saved as  .ASM assembler file, ready  to be
  178.   compiled by TP as CODE (not DATA), and used in your programs.
  179.  
  180.   The  resulting source  code Unit  .PAS  file  can be  directly used  in your
  181.   programs, and compiled  by Turbo Pascal as plain CODE  (not DATA), using the
  182.   USES  statement. I  can't remember   in which  exactly version  Turbo Pascal
  183.   started to  accept real Assembler  code mixed up  with Pascal source,  but I
  184.   think it was version  5.5. So, if this is true, you  can use TheImage in all
  185.   Turbo Pascal versions released after and including version 5.5.
  186.  
  187.   I  did  TheImage  back  in  April  1991.  At  that time, TheImage was called
  188.   ASM2TPU, a name I never liked. I'm using this program since then. Almost all
  189.   my programs used TheImage.
  190.  
  191.   The sintax of TheImage is quite simple:
  192.  
  193.       THEIMAGE filename[.ASM]...filename[.ASM]
  194.  
  195.   You must pass at least a parameter,  but as long as is TheImage concern, you
  196.   may  pass as  many parameters  as you  want. Zillions.  However, DOS has its
  197.   limits, so, don't you ever forget them <g>.
  198.  
  199.   Each parameter must represent a filename. You may specify drive and path, as
  200.   long  as  it  is  recognized  by  DOS.  And,  as  long  it is, TheImage will
  201.   recognized it.  You don't have  to specify the  file extension. By  default,
  202.   TheImage will add the [.ASM] extension if  you don't specify it. You may use
  203.   wildcards (? and *) in the exactly same  way you use them in most of the DOS
  204.   commands.
  205.  
  206.   Here's a sample list of valid commands:
  207.  
  208.      THEIMAGE *
  209.      (means all *.ASM files stored in the current directory)
  210.  
  211.      THEIMAGE *.ASM
  212.      (means exactly the same thing as the previous example)
  213.  
  214.      THEIMAGE C:\TP\*.ASM
  215.      (means all the .ASM files stored in the C:\TP directory)
  216.  
  217.      THEIMAGE * C:\TP\*
  218.      (means all  the .ASM files stored  in the current directory,  and all the
  219.      .ASM files stored in the C:\TP directory)
  220.  
  221.      THEIMAGE *.ASM C:\TP\*.ASM
  222.      (means exactly the same thing as the previous example)
  223.  
  224.      THEIMAGE C:\TP\* D:\MYPROG1\*.ASM * E:\MYPROGS\MYPROG2\*.ASM
  225.      (menas all  the .ASM files  stored in the  C:\TP directory, plus  all the
  226.      files stored in the D:\MYPROG1 directory,  plus all the .ASM files stored
  227.      in  the  current  directory,  plus  all  the  .ASM  files  stored  in the
  228.      E:\MYPROGS\MYPROG2 directory)
  229.  
  230.   Each filename  you specify must  be a TheDraw  .ASM file. Do  not change the
  231.   file contents, or TheImage may return an error.
  232.  
  233.   In order to explain how TheImage works, let me assume you are going to write
  234.   a  program (the  final step,  is not   the easiest  step, at  least in  this
  235.   case...). I'll use the files I have included in this package, as an example.
  236.   But first, take a look on  the contents of the DEMO_IMG.ASM and DEMO_IMG.PAS
  237.   files. It will help you understand how are things are done.
  238.  
  239.   First,  you  design  the  screen   image.  Run  TheDraw.  Refer  to  TheDraw
  240.   documention  on how  this wondefull  utility works.  After the  screen image
  241.   being finished, save it [ALT-S] as a TheDraw file (DEMO_IMG.TD).
  242.  
  243.   Without  quiting  TheDraw,  save  it  also  as  an .ASM file (DEMO_IMG.ASM).
  244.   Remember this: TheImage supports the entire  screen image, or a region block
  245.   of the screen.  After giving the adequate command, TheDraw  will ask you the
  246.   following question:
  247.  
  248.       "Save mode ? (Crunched, Ascii [no colors], or Normal)"
  249.  
  250.   You  may answer  either Crunched  or Normal.  TheImage supports  both modes.
  251.   Allways use the Crunch mode, since  TheDraw will compress the image data, in
  252.   order to take less CODE space. So, it will reduce your final .EXE file.
  253.  
  254.   TheDraw will then ask you another question:
  255.  
  256.       "Reference identifier to use? (IMAGEDATA)"
  257.  
  258.   By default, TheDraw  will use the IMAGEDATA identifier,  if you simply press
  259.   the [ENTER] key. This will by  the identifier prefix names for all variables
  260.   TheDraw  will save  on file,  and also  the name  TheImage will  give to the
  261.   procedure  (where  the  screen  image  will  be  stored)  as well as related
  262.   variable names, when it converts the file to .PAS.
  263.  
  264.   In the demo example, I have leave it with the default name IMAGEDATA.
  265.  
  266.   Next, TheDraw  will ask you  for the name  of the file  to be saved.  I have
  267.   answered DEMO_IMG.ASM.
  268.  
  269.   Quit TheDraw [ALT-X].
  270.  
  271.   Run the TheImage program using this command:
  272.  
  273.      THEIMAGE DEMO_IMG.ASM
  274.  
  275.   TheImage  will convert  this file,  and automaticly  names it  DEMO_IMG.PAS.
  276.   There  is no  way, or  need (as  least I  think so),  for you to specify the
  277.   output filename. The file will be  always stored in the same directory where
  278.   the imput .ASM file is located.
  279.  
  280.   Look at the  DEMO_IMG.PAS file. Particulary notice that  the screen image is
  281.   stored as  a PROCEDURE. This is  why the screen image  doesn't take a single
  282.   byte of DATA. NEVER, ever, call  this PROCEDURE, or your program (and Turbo)
  283.   will imediately crash.  This PROCEDURE is NOT to be  called, it's to be used
  284.   and linked into the .EXE file, if used (which is the hole idea).
  285.  
  286.   Ok, now your  are in programming mode, so  to speak, the last and  most hard
  287.   step of making a program, but the funnyest.
  288.  
  289.   Take a  look on the  DEMO.PAS file. It's  a sample demo  program for you  to
  290.   understand how to incorporate a TheDraw screen image, converted by TheImage,
  291.   into  your programs.  I have   included another  file THEDRAW.PAS,  which is
  292.   almost the same as is UNCRUNCH.PAS that is distributed along with TheDraw. I
  293.   have made some minor cosmetic changes,  and transformed the file into a full
  294.   Turbo Pascal unit, for easy use.  The THEDRAW.PAS unit have a special INLINE
  295.   which works real fast.
  296.  
  297.   Here's the magic line for displaying the screen image:
  298.  
  299.       UnCrunch(Addr(ImageData)^,Mem[Video_Addr:$0000],ImageData_Length);
  300.  
  301.   Please read  the remarks made by  Mr.Ian E. Davis in  the THEIMAGE.PAS file.
  302.   You can find  there important information about the  displaying of a TheDraw
  303.   screen image,  particulary when you don't  want to save the  complete screen
  304.   image, but only  a part of it (a box,  for instance). TheImage also supports
  305.   parts  of screen  images. The  process  remains  the same.  But some  slight
  306.   modifications are required. You must  calculate the screen address, which is
  307.   very easy. Refer ton the THEIMAGE.PAS remarks, for further information.
  308.  
  309.   And that's it. End of description.
  310.  
  311.  
  312.  
  313.                                 --- TOOLS ---
  314.  
  315.  
  316.  
  317.   This program was written using Borland's Turbo Pascal version 7.0.
  318.  
  319.   I  also used  The The  HeartWare Toolkit  v2.00 for  Turbo Pascal,  which is
  320.   Copyright (C) by José De Almeida & Luis Correia.
  321.  
  322.  
  323.  
  324. [end-of-file]
  325.